<%@page import="com.sap.conn.jco.JCoTable"%>
<%@page import="com.sap.conn.jco.JCoFunction"%>
<%@page import="com.sap.conn.jco.JCoDestination"%>
<%@page import="com.westvalley.sap.conn.SapConfig"%>
<%@ page language="java" contentType="text/html; charset=UTF8" pageEncoding="UTF8"%>
<%
	JCoDestination conn = SapConfig.connect();
	JCoFunction function = conn.getRepository().getFunction("ZMMFG01_002");
	JCoTable IT_SPXX = function.getTableParameterList().getTable("IT_SPXX");
	IT_SPXX.appendRow();
	IT_SPXX.setValue("BANFN", "10000342");	//采购申请编号
	//IT_SPXX.setValue("BNFPO", WorkFlowActionUtil.getFieldValue(this.mainTableInfo, ""));	//采购申请的项目编号
	IT_SPXX.setValue("APPROVE", "Y");	//审批标识(通过： Y  撤回： N)
	function.execute(conn);
	JCoTable ET_RETURN = function.getTableParameterList().getTable("ET_RETURN");
	String TYPE = ET_RETURN.getString("TYPE"); 	//返回结果(成功：S  失败： E)
	String MESSAGE = ET_RETURN.getString("MESSAGE"); 	//返回消息
%>
<html>
	<head>
		<meta charset="utf-8">
	</head>
	<body>
		返回结果:<input type="text" value="<%=TYPE %>"/><br/>
		返回消息:<textarea rows="50" cols="100"><%=MESSAGE %></textarea>
	</body>
</html>